package com.ytjj.qmyx.admin.controller;

import com.ytjj.common.api.CommonResult;
import com.ytjj.qmyx.admin.model.request.ReturnRechargeRequest;
import com.ytjj.qmyx.admin.service.ReturnRechargeService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @Description TODO
 * @ClassName ReturnRechargeController
 * 
 * 
 * @Version 1.0
 **/
@RestController
@RequestMapping("/returnRecharge")
public class ReturnRechargeController {

    @Resource
    private ReturnRechargeService returnRechargeService;

    @GetMapping("/list")
    public CommonResult selectList(ReturnRechargeRequest request) {
        return CommonResult.success(returnRechargeService.selectList(request));
    }

    @GetMapping("/auditRecharge")
    public CommonResult auditRecharge(@RequestParam Integer orderinfoId, @RequestParam Integer rechargeStatus) {
        returnRechargeService.auditRecharge(orderinfoId, rechargeStatus);
        return CommonResult.success();
    }
}